import Vue from "vue";
import Router from "vue-router";
import Home from "../views/Home.vue"
import Reg from "../views/Reg.vue"
import Regcode from "../components/Regcode"
import Regpass from "../components/Regpass"
import Brand from "../components/Brand"
import Sets from "../components/Sets"
import Address from "../components/Address"
import AddressEdit from "../components/AddressEdit"

import SearchPro   from "../components/SearchPro"
import Login from "../views/Login.vue"
import GoodsDetail from "../views/GoodsDetail.vue"
import My from "../views/My.vue"
import ShoppingCar from "../views/ShoppingCar.vue"
import Category from "../views/Category.vue"


// 把插件安装到Vue里
Vue.use(Router);

export default new Router({
    routes:[
        {
            path:"/",
            component:Home
        },
        {
            path:"/Reg",
            component:Reg
        },
        {
            path:"/Regcode",
            component:Regcode
        },
        {
            path:"/Regpass",
            component:Regpass
        },
        {
            path:"/Login",
            component:Login
        },
        {
            path:"/GoodsDetail/:goodsid",
            component:GoodsDetail
        },
        {
            path:"/My",
            component:My
        },
        {
            path:"/Sets",
            component:Sets
        },
        {
            path:"/Address",
            component:Address
        },
        {
            path:"/AddressEdit",
            component:AddressEdit
        },
        {
            path:"/ShoppingCar",
            component:ShoppingCar
        },
        {
            path:"/Category",
            component:Category
        },
        {
            path:"/Brand",
            component:Brand
        },
        {
            path:"/SearchPro",
            component:SearchPro
        },
    ]
});

